package com.devicemantra.coordinate.dataobjects;

import javax.jdo.annotations.*;
import com.google.appengine.api.datastore.Key;


@PersistenceCapable(identityType = IdentityType.APPLICATION, detachable ="true")
public class SubDepartment 
{
	@PrimaryKey
    @Persistent  
    private Key mSubDepartmentId;
	
	@Persistent 
	private String mDepartmentName;
	
	@Persistent 
	private String mSubDepartmentName;
	
	@Persistent(defaultFetchGroup="true")
	private CDepartment mMappedDepartment;
	
	public SubDepartment(String pSubDepartmentName)
	{
		
		mSubDepartmentName = pSubDepartmentName;
	}
	
	public String getSubDepartmentName()
	{
		return mSubDepartmentName;
	}
	
	public String getSubDepartmentId()
	{
		return mSubDepartmentId.toString();
	}
	
	public void setSubDepartmentId(Key pSubDepartmentId)
	{
		mSubDepartmentId = pSubDepartmentId;
	}
	
	public CDepartment getParentDepartment()
	{
		return mMappedDepartment;
	}
	
	
	

}
